<div>
    <form class="form-horizontal bv-form"  role="form"  id="addForm">
        <fieldset>
            <legend>基本信息</legend>
            <div class="form-group">
                <label class="col-sm-3 control-label">房产名称</label>
                <div class="col-sm-5">
                    <input type="text"  class="form-control"  name="name" id="house_name">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">简介</label>
                <div class="col-sm-5">
                    <textarea name="introduce" class="form-control" cols="30" rows="10" id="introduce"></textarea>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">房产类型</label>
                <div class="col-sm-5">
                    <input type="checkbox" name="type[]" value="一室">一室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="二室">二室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="三室">三室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="四室">四室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="五室">五室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="六室">六室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="六室">七室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="八室">八室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="九室">九室&nbsp;&nbsp;&nbsp;
                    <input type="checkbox" name="type[]" value="十室">十室&nbsp;&nbsp;&nbsp;
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">房产面积</label>
                <div class="col-sm-5">
                    <input type="text"  class="form-control"  name="areas" id="areas">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">房产价格</label>
                <div class="col-sm-5">
                    <input type="text"  class="form-control"  name="price" id="price">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">地区</label>
                <div class="col-sm-5">
                    <select name="place" id="place" class="form-control">
                        <option value="">请选择</option>
                        {foreach name="$data" item="vo"}
                            <option value="{$vo['place_id']}">{$vo['place_name']}</option>
                        {/foreach}
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label yl">缩略图</label>
                <div class="col-sm-5">
                    <a href="javascript:;" class="file">选择文件
                        <input type="file" name="file" id="data_photo" onchange="bbbb(this);">
                    </a>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label ">预览图片</label>
                <div class="col-sm-3 file1_1" id="androimg_file" style="float:left">
                </div>
            </div>

        </fieldset>
    </form>

</div>

<script type="text/javascript">
    function bbbb(file) {
        var prevDiv = document.getElementById('androimg_file');
        if (file.files && file.files[0]) {
            var reader = new FileReader();
            reader.onload = function(evt){
                prevDiv.innerHTML = '<img src="' + evt.target.result + '" height="150" width="250"/>';
            }
            reader.readAsDataURL(file.files[0]);
        } else {
            prevDiv.innerHTML = '<div class="img" style="filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod=scale,src=\'' + file.value + '\'"></div>';
        }
    }
</script>